const user = (state = {
  isLogin: false,
  userid: '',
  token: ''
}, action) => {
  switch (action.type) {
    case 'UPDATA_ISLOGIN':
      return { ...state, isLogin: action.payload }
    case 'UPDATA_USERID':
      return { ...state, userid: action.payload }
    case 'UPDATA_TOKEN':
      return { ...state, token: action.payload }
    default:
      return state
  }
}

export default user